import request from '@/utils/request'

// 查询消息中心列表
export function listEvent(query) {
  return request({
    url: '/ehr/event/list',
    method: 'get',
    params: query
  })
}

// 查询消息中心详细
export function getEvent(communicationEventId) {
  return request({
    url: '/ehr/event/' + communicationEventId,
    method: 'get'
  })
}

// 新增消息中心
export function addEvent(data) {
  return request({
    url: '/ehr/event',
    method: 'post',
    data: data
  })
}

// 修改消息中心
export function updateEvent(data) {
  return request({
    url: '/ehr/event',
    method: 'put',
    data: data
  })
}

// 删除消息中心
export function delEvent(communicationEventId) {
  return request({
    url: '/ehr/event/' + communicationEventId,
    method: 'delete'
  })
}

